package com.qujia.station.service;


import com.baomidou.mybatisplus.extension.service.IService;
import com.qujia.station.domain.TeamManagement;
import com.qujia.station.domain.dto.AddTeamManagement;
import com.qujia.station.domain.dto.TeamManagementDto;
import com.qujia.station.domain.vo.DistrictEnterpriseVo;
import com.qujia.station.domain.vo.RegionalReportVo;
import com.qujia.station.domain.vo.TeamManagementVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author PC
 * @description 针对表【team_management(团队管理表)】的数据库操作Service
 * @createDate 2023-08-29 16:32:10
 */
public interface TeamManagementService extends IService<TeamManagement> {
    /**
     * 新增团队
     * @param addTeamManagement
     * @return
     */
    AddTeamManagement addTeam(@Param("addTeamManagement") AddTeamManagement addTeamManagement);

    /**
     * 删除团队
     * @param ids
     */
    void deleteTeamManagement(String ids);

    /**
     * 更改团队信息
     * @param addTeamManagement
     * @return
     */
    AddTeamManagement updateTeamManagement(@Param("addTeamManagement") AddTeamManagement addTeamManagement);


    /**
     * 查询团队信息
     * @param addTeamManagement
     * @return
     */
    List<TeamManagementVo> selectTeamManagement(TeamManagementDto teamManagementDto);

    /**
     * 获取团队下的油企id
     * @param id
     * @return
     */
    List<Long> getManagerEnterpriseId(Long id);

    /**
     * 更改团队成员
     * @param teamId
     * @param salesmanId
     */
    void updateTeamMemberId(Long teamId,Long salesmanId);

    /**
     * 通过地区获取油企id
     * @param district
     * @return
     */
    List<Long> getEnterpriseByDistrict(String district);

    List<DistrictEnterpriseVo> getEnterpriseId(Integer district);

    List<RegionalReportVo> getRegionalReport(List<Integer> districtIds, String beginTime,String endTime,Integer pageNum,Integer pageSize,Integer sorted);

}
